<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type"/>
<link href="themes01/default/clientPublic.css" rel="stylesheet" type="text/css"/>
<link href="themes01/default/codeMgr.css" rel="stylesheet" type="text/css"/>
<link href="themes01/default/tabSwitch.css" rel="stylesheet" type="text/css"/>
<link rel="stylesheet" type="text/css" href="themes01/default/pstyle.css">
<script type="text/javascript" src="javascripts01/jquery.js"></script>
<script type="text/javascript" src="javascripts01/common.js"></script>
<script language="javascript" type="text/javascript" src="DatePicker/WdatePicker.js"></script>
<title>Office 515158 2011 OA办公系统</title>
 
</head>
<body>
<div id="Holder">
<div id="MainPage">

 
 
<div id="Subnav">
 
<ul>
<?php
//定义标题
$nums=83;
global $db;
$query = $db->query("SELECT * FROM ".DB_TABLEPRE."menu where fatherid='11' and menutype='0' ORDER BY menunum Asc");
	while ($row = $db->fetch_array($query)) {
?>
<li><a href="<?=$row[menuurl]?>"  <? if($nums==$row[menuid]){?> id="Subnavb"<? }?>><?=$row[menuname]?></a></li>
<?php
	}
?>


</ul>
</div>
<script Language="JavaScript"> 
function CheckForm()
{
   if(document.save.user.value=="")
   { alert("单位员工不能为空！");
     document.save.user.focus();
     return (false);
   }
   if(document.save.project.value=="")
   { alert("奖惩项目不能为空！");
     document.save.project.focus();
     return (false);
   }
   if(document.save.rewardsdate.value=="")
   { alert("奖惩日期不能为空！");
     document.save.rewardsdate.focus();
     return (false);
   }
   if(document.save.rewardskey.value=="")
   { alert("奖惩属性不能为空！");
     document.save.rewardskey.focus();
     return (false);
   }
   if(document.save.price.value=="")
   { alert("奖惩金额不能为空！");
     document.save.price.focus();
     return (false);
   }
   
   return true;
}
function sendForm()
{
   if(CheckForm())
      document.save.submit();
}
</script>
<form name="save" method="post" action="?ac=edit&do=save&fileurl=rewards">
	<input type="hidden" name="savetype" value="edit" />
	<input type="hidden" name="id" value="<?=$blog['id']?>" />
<table class="TableTop" width="90%">
   <tr>
      <td class="left"></td>
      <td class="center">编辑奖惩记录</td>
      <td class="right"></td>
   </tr>
</table>
 <table class="TableBlock no-top-border" width="90%">
   
	<tr>
      <td nowrap class="TableContent" width="15%"> 单位员工：<? get_user_add_help()?></td>
      <td class="TableData">
      
	  <?php
	  get_oa_member_public(1,"user",$blog['user'],"+选择人员",70,20)
	  ?>
	  </td>
    </tr>
	<tr>
      <td nowrap class="TableContent" width="15%"> 奖惩项目：<? get_user_add_help()?></td>
      <td class="TableData">
      <select name="project">
			<option value="0" selected="selected">请选择项目</option>
			<?=get_inc_office_type($blog['project'],19)?>
			</select></td>
    </tr>
	<tr>
      <td nowrap class="TableContent" width="15%"> 奖惩日期：<? get_user_add_help()?></td>
      <td class="TableData">
      <input type="text" name="rewardsdate" class="BigInput" style="width:168px;" size="20" value="<?=$blog['rewardsdate']?>" onClick="WdatePicker();" /></td>
    </tr>

	<tr>
      <td nowrap class="TableContent" width="15%"> 工资月份：</td>
      <td class="TableData">
	  <?php
			$startdate=explode('-',$blog['wagesmonth']); 
            ?>
      <select name="wagesmonth_year">
			    <?php
				for($i=get_date('Y',PHP_TIME)-5;$i<=get_date('Y',PHP_TIME)+5;$i++){
				if (strlen($i)<2){
				$j="0".$i;
				}else{
				$j=$i;
				}
				?>
				<option value="<?=$j?>" <?php if($startdate[0]==$j){?>selected="selected"<?php }?>><?=$j?></option>
				<?php } ?>
				</select>年<select name="wagesmonth_month">
			    <?php
				for($i=1;$i<=12;$i++){
				if (strlen($i)<2){
				$j="0".$i;
				}else{
				$j=$i;
				}
				?>
				<option value="<?=$j?>" <?php if($startdate[1]==$j){?>selected="selected"<?php }?>><?=$j?></option>
				<?php } ?>
				</select>月</td>
    </tr>
	
	<tr>
      <td nowrap class="TableContent" width="15%"> 奖惩属性：<? get_user_add_help()?></td>
      <td class="TableData">
	  <input name="rewardskey" type="radio" value="1" <?php if($blog['rewardskey']=='1'){?>checked<?php }?> />奖励
	  <input name="rewardskey" type="radio" value="2" <?php if($blog['rewardskey']=='2'){?>checked<?php }?> />惩罚
      
	  </td>
    </tr>
	<tr>
      <td nowrap class="TableContent" width="15%"> 奖惩金额：<? get_user_add_help()?></td>
      <td class="TableData">
      <input type="text" name="price" class="BigInput" size="15" value="<?=$blog['price']?>" onKeyUp="value=value.replace(/[^0-9^.]/g,'');" /> RMB</td>
    </tr>
	
	
	<tr>
      <td nowrap class="TableContent" width="15%"> 备注：</td>
      <td class="TableData">
        <textarea name="content" cols="60" rows="4" class="BigInput"><?=$blog['content']?></textarea></td>
    </tr>
	
    
    <tr align="center" class="TableControl">
      <td colspan="2" nowrap height="35">

		<input type="button" name="Submit" value="保存信息" class="BigButton" onclick="sendForm();">
        
      </td>
    </tr>
  </table>
</form>
</div>
</div>
 
</body>
</html>
